package com.beta.admin.controller;

import com.beta.admin.support.web.BaseController;
import com.beta.common.web.ContentType;
import com.beta.service.IStockLocationsService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

/**
 * Created by lichao on 2017/2/4.
 */
@RestController
@RequestMapping(value = RequestMappingConstants.MAPPING_PREFIX + "/stock_locations")
public class StockLocationsController extends BaseController {
    @Autowired
    private IStockLocationsService stockLocationsService;
    @GetMapping(value = "" ,produces = ContentType.JSON)
    public Object getStockLocations(@RequestParam("searchName")String searchName){
        return stockLocationsService.getStockLocations(getMybatisPage(),searchName);
    }
}
